package com.feng.cloud.auth.service;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import java.io.IOException;

/**
 * @ClassName ValidateCodeService
 * @Description TODO
 * @Author Better Feng
 * @Date 2019/12/16 13:55
 * @Version 1.0
 **/
public interface ValidateCodeService {
    /**
     * 生成验证码
     *
     * @param request  HttpServletRequest
     * @param response HttpServletResponse
     */
    void create(HttpServletRequest request, HttpServletResponse response) throws IOException;

    /**
     * 校验验证码
     *
     * @param key   前端上送 key
     * @param value 前端上送待校验值
     */
    void check(String key, String value);

    /**
     * 校验滑动验证码
     * @param captchaVerification captchaVerification
     */
    void captchaVerification(String captchaVerification);

}
